/**
 * Media
 */

img {
	border-radius: 3px;
}

.page-content,
.entry-content,
.comment-content {
	img.wp-smiley {
		border: none;
		margin-bottom: 0;
		margin-top: 0;
		padding: 0;
		display: inline-block;
		border-radius: 0;
	}
}

/**
 * Captions
 */
.wp-caption {
	margin-bottom: $vspacing;
	max-width: 100%;

	img[class*="wp-image-"] {
		display: block;
		margin: 0 auto;
	}
	.wp-caption-text {
		text-align: left;
		font-style: italic;
		border-bottom: 2px solid $color_border;
		padding: 1em 0;
	}
}

/**
 * Galleries
 */
.gallery {
	@extend %clearfix;
	margin-bottom: $vspacing;

	.gallery-item {
		float: left;

		.gallery-icon {
			a {
				display: block;
			}

			img {
				border: none;
				height: auto;
				margin: 0 auto;
			}
		}

		.gallery-caption {
			margin: 0;
			text-align: center;
		}
	}

	&.gallery-columns-1 {
		.gallery-item {
			width: 100%;
		}
	}

	&.gallery-columns-2 {
		.gallery-item {
			width: 50%;
		}
	}

	&.gallery-columns-3 {
		.gallery-item {
			width: 33.3%;
		}
	}

	&.gallery-columns-4 {
		.gallery-item {
			width: 25%;
		}
	}

	&.gallery-columns-5 {
		.gallery-item {
			width: 20%;
		}
	}

	&.gallery-columns-6 {
		.gallery-item {
			width: 16.666666667%;
		}
	}

	&.gallery-columns-7 {
		.gallery-item {
			width: 14.285714286%;
		}
	}

	&.gallery-columns-8 {
		.gallery-item {
			width: 12.5%;
		}
	}

	&.gallery-columns-9 {
		.gallery-item {
			width: 11.111111111%;
		}
	}
}

/**
 * Embeds
 */
embed,
iframe,
object,
video {
	max-width: 100%;
}